import { defineApplicationConfig } from '@vben/vite-config';

export default defineApplicationConfig({
  overrides: {
    optimizeDeps: {
      include: [
        'echarts/core',
        'echarts/charts',
        'echarts/components',
        'echarts/renderers',
        'qrcode',
        '@iconify/iconify',
        'ant-design-vue/es/locale/zh_CN',
        'ant-design-vue/es/locale/en_US'
      ]
    }
    // server: {
    //   proxy: {
    //     '/api': {
    //       target: 'http://192.168.64.201:5000',
    //       changeOrigin: true,
    //       ws: true,
    //       rewrite: (path) => path.replace(new RegExp(`^/api`), ''),
    //       // only https
    //       secure: false
    //     },
    //     '/upload': {
    //       target: 'http://127.0.0.1:5000/upload',
    //       changeOrigin: true,
    //       ws: true,
    //       rewrite: (path) => path.replace(new RegExp(`^/upload`), ''),
    //     },
    //   },
    // },
  }
});
